﻿// Decompiled with JetBrains decompiler
// Type: UnityEngine.Experimental.GlobalIllumination.Cookie
// Assembly: UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: E6AE6B5A-2752-4B07-9528-C8B77C62CE79
// Assembly location: C:\Users\windys\Unity\2021.3.39f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.CoreModule.dll
// XML documentation location: C:\Users\windys\Unity\2021.3.39f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.CoreModule.xml

#nullable disable
namespace UnityEngine.Experimental.GlobalIllumination
{
  /// <summary>
  ///   <para>A helper structure used to initialize a LightDataGI structure with cookie information.</para>
  /// </summary>
  public struct Cookie
  {
    /// <summary>
    ///   <para>The cookie texture's instance id projected by the light.</para>
    /// </summary>
    public int instanceID;
    /// <summary>
    ///   <para>The uniform scale factor for downscaling cookies during lightmapping. Can be used as an optimization when full resolution cookies are not needed for indirect lighting.</para>
    /// </summary>
    public float scale;
    /// <summary>
    ///   <para>The scale factors controlling how the directional light's cookie is projected into the scene. This parameter should be set to 1 for all other light types.</para>
    /// </summary>
    public Vector2 sizes;

    /// <summary>
    ///   <para>Returns a default initialized cookie helper struct.</para>
    /// </summary>
    public static Cookie Defaults()
    {
      Cookie cookie;
      cookie.instanceID = 0;
      cookie.scale = 1f;
      cookie.sizes = new Vector2(1f, 1f);
      return cookie;
    }
  }
}
